package com.css.zfzx.fxpg.modules.percent.daynight.service;

import com.alibaba.fastjson.JSONObject;
import com.css.zfzx.fxpg.modules.percent.daynight.repository.entity.FxDayNightPercentEntity;
import com.css.zfzx.fxpg.modules.percent.daynight.viewobjects.FxDayNightPercentQueryParams;
import com.css.bpm.platform.sys.dict.repository.entity.DictItemEntity;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * @author leon
 * @date 2020-11-12
 */

public interface FxDayNightPercentService {

    JSONObject queryFxDayNightPercents(FxDayNightPercentQueryParams queryParams, int curPage, int pageSize);

    FxDayNightPercentEntity getFxDayNightPercent(String id);

    /**
     * 根据房屋类别判断是否存在
     */
    boolean isRepeat(String houseType);

    FxDayNightPercentEntity saveFxDayNightPercent(FxDayNightPercentEntity fxDayNightPercent);

    /**
     * 根据房屋类别判断存在后，覆盖原数据
     */
    void coverFxDayNightPercent(FxDayNightPercentEntity fxDayNightPercent);

    FxDayNightPercentEntity updateFxDayNightPercent(FxDayNightPercentEntity fxDayNightPercent);

    void deleteFxDayNightPercents(List<String> ids);

    List<DictItemEntity> getValidDictItemsByDictCode(String dictCode);

    String exportExcel(FxDayNightPercentQueryParams queryParams, HttpServletResponse response);

}
